<script>
import store from '@/store/globalStore.js'
export default {
  name: 'App',
  data () {
    return {
      sysInfo: null
    }
  },
  created () {
    this.getSysInfo()
    // console.log(this.sysInfo)
    store.commit('commitModel', this.sysInfo.model)
    store.commit('commitVersion', this.sysInfo.version)
    store.commit('commitSystem', this.sysInfo.system)
    store.commit('commitPlatform', this.sysInfo.platform)
    store.commit('commitSDKVersion', this.sysInfo.SDKVersion)
  },
  methods: {
    // 获取系统信息
    getSysInfo () {
      this.sysInfo = wx.getSystemInfoSync()
    }
  }
}
</script>

<style lang="sass">
@import 'assets/global.scss';
</style>
